<?php
/**
 * Created by PhpStorm.
 * User: zhou
 * Date: 2019/3/26
 * Time: 下午10:41
 */

namespace App\Http\Controllers\Api\Hotel;


use App\Http\Controllers\ApiController;
use App\Models\TransactionLog;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Validator;

class TransactionLogsController extends ApiController
{
    public function loglist(Request $request)
    {
        $validator = Validator::make($request->all(), [
            'hotel_open_id'   => 'required'
        ]);

        if($validator->fails()){
            return self::response(null,self::ERROR_CODE,$validator);
        }

        $list = TransactionLog::get_logs($request->all());
        return self::response($list);
    }

}